<script type="text/javascript">
tinyMCE.init({
		// General options
		mode : "exact",
		elements : "elm2",
		theme : "advanced",
		skin : "o2k7",
		plugins : "pagebreak,style,layer,table,save,advhr,advimage,advlink,emotions,iespell,insertdatetime,preview,media,searchreplace,print,contextmenu,paste,directionality,fullscreen,noneditable,visualchars,nonbreaking,xhtmlxtras,template,inlinepopups,autosave",

		// Theme options
		theme_advanced_buttons1 : "save,newdocument,|,bold,italic,underline,strikethrough,|,justifyleft,justifycenter,justifyright,justifyfull,styleselect,formatselect,fontselect,fontsizeselect",
		theme_advanced_buttons2 : "cut,copy,paste,pastetext,pasteword,|,search,replace,|,bullist,numlist,|,outdent,indent,blockquote,|,undo,redo,|,link,unlink,anchor,image,cleanup,code,|,insertdate,inserttime,preview,|,forecolor,backcolor",
		theme_advanced_buttons3 : "tablecontrols,|,hr,removeformat,visualaid,|,sub,sup,|,charmap,emotions,iespell,media,advhr,|,print,|,ltr,rtl,|,fullscreen",
		theme_advanced_buttons4 : "insertlayer,moveforward,movebackward,absolute,|,styleprops,|,cite,abbr,acronym,del,ins,attribs,|,visualchars,nonbreaking,template,pagebreak,restoredraft",
		theme_advanced_toolbar_location : "top",
		theme_advanced_toolbar_align : "left",
		theme_advanced_statusbar_location : "bottom",
		theme_advanced_resizing : true,

		// Example content CSS (should be your site CSS)
		content_css : "css/content.css",

		// Drop lists for link/image/media/template dialogs
		template_external_list_url : "lists/template_list.js",
		external_link_list_url : "lists/link_list.js",
		external_image_list_url : "lists/image_list.js",
		media_external_list_url : "lists/media_list.js",

		// Replace values for the template plugin
		template_replace_values : {
			username : "Some User",
			staffid : "991234"
		}
	});
</script>

<form name="addform" action="index.php?tc=blog_addcode" method="post" onSubmit="return ValidateForm(this);" enctype="multipart/form-data">
<?php
if($_REQUEST['News'] == 'true')
{?>
<table align="center" border="0">
	<tr>
    	<td align="center">
        <div class="sucmsg"><img src="images/information.png" align="absmiddle" />&nbsp;Blog submitted successfully</div></td>
    </tr>    
    </table>
<?php } ?>
<?php
if($_REQUEST['News'] == 'f')
{?>
<table align="center" border="0">
	<tr>
    	<td align="center">
        <div class="sucmsg"><img src="images/error.png" align="absmiddle" />&nbsp;Only .doc files can be uploaded.</div></td>
    </tr>    
    </table>
<?php } ?>
<table width="99%" align="center" border="0"  class="list" cellpadding="5">
<thead>
<tr>
	<td colspan="2" align="left">
        <div style="float:left">Add Blog Details</div>
        <div style="float:right"><a href="index.php?tc=blog">Back</a></div>
    </td>
</tr>
</thead>
<tr>
	<td align="right" width="150">Title</td>
    <td align="left"><input class="text" name="name" type="text"/></td>
</tr>
<tr>
  <td align="right" width="150">Blog Details</td>
  <td align="left"><textarea name="news" id="elm2" rows="6" cols="60"></textarea></td>
</tr>
<tr>
  <td align="right" width="150">Status :</td>
  <td align="left">
  <input name="authorised" type="radio" class="text" value=1 checked="checked" />&nbsp;Active&nbsp;&nbsp;
  <input class="text" name="authorised" type="radio" value=0 />&nbsp;Deactive</td>
</tr>
<tr>
	<td align="right" width="150"></td>
    <td colspan="2" align="left">
    <input type="submit" value="Submit" name="save_news">&nbsp;
    <input type="reset" name="reset" value="Clear" /></td>
</tr>
</table>
</form>